﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;
using QLHocSinh.DTO;
using QLHocSinh.DAO;
using QLHocSinh.BUS;

namespace QLHocSinh.BUS
{
    public enum UserBUSResult
    {
        OK,
        USERNAMEERROR,
        PASSWORDERROR,
        DAOERROR
    }
    class UserBUS
    {
        public static DataTable LayDanhSachUser()
        {
            return UserDAO.SelectAll();
        }
        public static UserBUSResult KiemTraUser(UserDTO User)
        {
            if (!UserDAO.KiemTraUser(User))
                return UserBUSResult.DAOERROR;
            return UserBUSResult.OK;
        }
    }
}
